import api from './index'
// axios
import request from '@/utils/request'
import qs from 'qs'
//
export function queryCompanyInfo(data) {
  return request({
    url: api.queryCompanyInfo,
    method: 'post',
    data: qs.stringify(data)
  })
}
//
export function getCompanyInfo(data) {
  return request({
    url: api.getCompanyInfo,
    method: 'post',
    data: qs.stringify(data)
  })
}
//
export function queryCompanyImage(data) {
  return request({
    url: api.queryCompanyImage,
    method: 'post',
    data: qs.stringify(data)
  })
}
//
export function queryProductCategory(data) {
  return request({
    url: api.queryProductCategory,
    method: 'post',
    data: qs.stringify(data)
  })
}
//
export function queryProductInfo(data) {
  return request({
    url: api.queryProductInfo,
    method: 'post',
    data: qs.stringify(data)
  })
}

export function queryProductSkuList(data) {
  return request({
    url: api.queryProductSkuList,
    method: 'post',
    data: qs.stringify(data)
  })
}

export function queryZhyeByAgencyid(data) {
  return request({
    url: api.queryZhyeByAgencyid,
    method: 'post',
    data: qs.stringify(data)
  })
}



//
export function getProductInfo(data) {
  return request({
    url: api.getProductInfo,
    method: 'post',
    data: qs.stringify(data)
  })
}
//
export function saveAgencyChat(data) {
  return request({
    url: api.saveAgencyChat,
    method: 'post',
    data: qs.stringify(data)
  })
}
//
export function queryPlatformProductCategory(data) {
  return request({
    url: api.queryPlatformProductCategory,
    method: 'post',
    data: qs.stringify(data)
  })
}

export function getPrivacyPolicy(data) {
  return request({
    url: api.getPrivacyPolicy,
    method: 'post',
    data: qs.stringify(data)
  })
}

export function saveApplySample(data) {
  return request({
    url: api.saveApplySample,
    method: 'post',
    data: qs.stringify(data)
  })
}

export function saveShareInfo(data) {
  return request({
    url: api.addShareInfo,
    method: 'post',
    data: qs.stringify(data)
  })
}

export function uploadShareImg(data) {
  return request({
    url: api.uploadfile,
    method: 'post',
    data: data
  })
}

/**
 * 查询圈子信息
 * @param data
 */
export function queryShareInfo(data) {
  return request({
    url: api.queryShareInfo,
    method: 'post',
    data:  qs.stringify(data)
  })
}

/**
 * 查询圈子信息
 * @param data
 */
export function addShareStoreInfo(data) {
  return request({
    url: api.addShareStoreInfo,
    method: 'post',
    data:  qs.stringify(data)
  })
}

/**
 * 点击查看增加一次阅读数
 * @param data
 */
export function editShareReadNum(data) {
  return request({
    url: api.editShareReadNum,
    method: 'post',
    data:  qs.stringify(data)
  })
}


/**
 * 保存留言信息
 * @param data
 */
export function addShareLy(data) {
  return request({
    url: api.addShareLy,
    method: 'post',
    data:  qs.stringify(data)
  })
}


/**
 * 保存留言信息
 * @param data
 */
export function queryShareLy(data) {
  return request({
    url: api.queryShareLy,
    method: 'post',
    data:  qs.stringify(data)
  })
}

/**
 * 查询我发布的信息
 * @param data
 */
export function queryMySharedInfo(data) {
  return request({
    url: api.queryMySharedInfo,
    method: 'post',
    data:  qs.stringify(data)
  })
}

/**
 * 查询我收藏的信息
 * @param data
 */
export function queryMyStoredShareInfo(data) {
  return request({
    url: api.queryMyStoredShareInfo,
    method: 'post',
    data:  qs.stringify(data)
  })
}

/**
 * 查询我留言过的信息
 * @param data
 */
export function queryHasMyLyShareInfo(data) {
  return request({
    url: api.queryHasMyLyShareInfo,
    method: 'post',
    data:  qs.stringify(data)
  })
}


/**
 * 查询我留言过的信息
 * @param data
 */
export function queryAgencyinfo(data) {
  return request({
    url: api.queryAgencyinfo,
    method: 'post',
    data:  qs.stringify(data)
  })
}


/**
 * 查询我留言过的信息
 * @param data
 */
export function queryCompanylist(data) {
  return request({
    url: api.queryCompanylist,
    method: 'post',
    data:  qs.stringify(data)
  })
}

export function addLyhfinfo(data) {
  return request({
    url: api.addLyhfinfo,
    method: 'post',
    data:  qs.stringify(data)
  })
}


// 新增【请填写功能名称】
export function addReadLog(data) {
  return request({
    url: api.addReadLog,
    method: 'post',
    data: qs.stringify(data)
  })
}


// 新增【请填写功能名称】
export function saveReport(data) {
  return request({
    url: api.saveReport,
    method: 'post',
    data: qs.stringify(data)
  })
}

// 新增【请填写功能名称】
export function saveDkinfo(data) {
  return request({
    url: api.saveDkinfo,
    method: 'post',
    data: qs.stringify(data)
  })
}


// 新增【请填写功能名称】
export function saveReportReadNum(data) {
  return request({
    url: api.saveReportReadNum,
    method: 'post',
    data: qs.stringify(data)
  })
}


// 新增商品SKU
export function queryProperties(data) {
  return request({
    url: api.queryProperties,
    method: 'post',
    data: qs.stringify(data)
  })
}

export  function  queryProductSku(data) {
  return request({
    url: api.queryProductSku,
    method: 'post',
    data: qs.stringify(data)
  })
}


export  function  saveAgencyAddress(data) {
  return request({
    url: api.saveAgencyAddress,
    method: 'post',
    data: qs.stringify(data)
  })
}

export  function  queryAgenyAddress(data) {
  return request({
    url: api.queryAgenyAddress,
    method: 'post',
    data: qs.stringify(data)
  })
}


export  function  queryAddressById(data) {
  return request({
    url: api.queryAddressById,
    method: 'post',
    data: qs.stringify(data)
  })
}


export  function  updateAgencyAddress(data) {
  return request({
    url: api.updateAgencyAddress,
    method: 'post',
    data: qs.stringify(data)
  })
}


export  function  saveAgencyOrder(data) {
  return request({
    url: api.saveAgencyOrder,
    method: 'post',
    data: qs.stringify(data)
  })
}


export  function  queryAgencyOrder(data) {
  return request({
    url: api.queryAgencyOrder,
    method: 'post',
    data: qs.stringify(data)
  })
}


export  function  queryAgencyOrderStatInfo(data) {
  return request({
    url: api.queryAgencyOrderStatInfo,
    method: 'post',
    data: qs.stringify(data)
  })
}


export  function  cancelAgencyOrder(data) {
  return request({
    url: api.cancelAgencyOrder,
    method: 'post',
    data: qs.stringify(data)
  })
}

export  function  queryOrderInfo(data) {
  return request({
    url: api.queryOrderInfo,
    method: 'post',
    data: qs.stringify(data)
  })
}


export  function  queryDictData(data) {
  return request({
    url: api.queryDictData,
    method: 'post',
    data: qs.stringify(data)
  })
}


export  function  saveZpinfo(data) {
  return request({
    url: api.saveZpinfo,
    method: 'post',
    data: qs.stringify(data)
  })
}


export  function  getAgencyInfo(data) {
  return request({
    url: api.getAgencyInfo,
    method: 'post',
    data: qs.stringify(data)
  })
}


export function getAccessToken(query) {
  return request({
    url: api.getAccessToken,
    method: 'get',
    params: query
  }) 
}

export function getUserInfo(query) {
  return request({
    url: api.getUserInfo,
    method: 'get',
    params: query
  })
}

export function addHyinfo(data) {
  return request({
    url: api.addHyinfo,
    method: 'post',
    data: qs.stringify(data)
  })
}

export function getHyinfo(query) {
  return request({
    url: api.getHyinfo,
    method: 'get',
    params: query
  })
}

export function queryHyinfoByOpenid(query) {
  return request({
    url: api.queryHyinfoByOpenid,
    method: 'get',
    params: query
  })
}

export function queryAgencyChatList(query) {
  return request({
    url: api.queryAgencyChatList,
    method: 'get',
    params: query
  }) 
}

export function queryAppalySampleList(query) {
  return request({
    url: api.queryAppalySampleList,
    method: 'get',
    params: query
  }) 
}